package com.doctcloud.hisinfo.api;

import com.doctcloud.common.core.constant.ServiceNameConstants;
import com.doctcloud.common.core.domain.R;
import com.doctcloud.hisinfo.api.factory.RemoteHisCommFallbackFactory;
import com.doctcloud.hisinfo.histable.domain.comm.DeptDictDo;
import com.doctcloud.hisinfo.histable.domain.comm.PriceListDo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

import java.util.List;

/**
 * 科室调用服务
 *
 * @author doctCloud samula
 */
//@FeignClient(contextId = "remoteCommonService", configuration = FeignConfig.class, value = ServiceNameConstants.HIS_COMMON_SERVICE, fallbackFactory = RemoteHisCommFallbackFactory.class)
@FeignClient(contextId = "remoteCommonService", value = ServiceNameConstants.HIS_COMMON_SERVICE, fallbackFactory = RemoteHisCommFallbackFactory.class)
public interface RemoteHisCommonService {
    @GetMapping("/comm/dept/dblist")
    public R<List<DeptDictDo>> deptListByDB();
    @GetMapping("/comm/dept/dbquerybycode/{deptCode}")
    public R<DeptDictDo> dbqueryDeptByDB(@PathVariable("deptCode")  String deptCode);
    @GetMapping("/comm/pricelist/listall")
    R<List<PriceListDo>> dbPriceListAll();
}
